<!DOCTYPE html>
<html>
<head>
	<meta charset="UTF-8">
	<title>文章列表</title>
	<script src="__JS__/jquery-2.1.4.min.js"></script>
	<style>
		.container{
			width: 1024px;
			text-align: center;
		}
		.clear{
			clear: both;
		}
		.fl{
			float: left;
		}
		.fr{
			float: right;
		}
		li{
			list-style: none;
		}
		li.fl{
			list-style: none;
		}
		.gray{
			color: gray;
		}
	</style>
	<script type="text/javascript">
		$(function(){
			<?php
				if(isset($_GET['type'])){
					$type = I('get.type');
					?>
					$('#type a').removeClass('gray');
					$('#type a[href*="type/{$type}"]').addClass('gray');
					<?php
				}
			?>
		})
	</script>
</head>
<body>
	<div class="container">
		<h1>文章列表</h1>
		<div id="type" class="clear">
			<a href="__URL__/index">全部</a>
			<a href="__URL__/index/type/1">安全</a> &nbsp;
			<a href="__URL__/index/type/0">不安全</a>
		</div>
		<a href="__URL__/post" class="fr">发布文章</a>
		<br>
		<ul>
			<volist name="list" id="vo">

				<li>{$vo.id}|<a href="__URL__/detail/id/{$vo.id}">{$vo.title}</a>|{$vo.create_time}|{$vo['type']?'不安全':'安全'}</li>
			</volist>
			<empty name="list">还没发布文章</empty>
		</ul>
	</div>
</body>
</html>